/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 邓大帅
 * Date: 2022-11-16
 * Time: 10:39
 */
public class ScoreCalculation {
    public static void main(String[] args) {
        int flag = 1;
        float sum = 0;
        for (int i = 1; i <= 100 ; i++) {
            sum += flag*(1.0 / i);
            flag = -flag;
        }
        System.out.println(sum);
    }
}
